#ifndef __LIB_KERNEL_BITMAP_H__
#define __LIB_KERNEL_BITMAP_H__

#include "../stdint.h"

struct bitmap
{
	uint8_t* addr;
	uint32_t len;		// byte len
};

int8_t bitmap_init(struct bitmap* p, uint8_t* addr, uint32_t len);
int32_t bitmap_scan_test(struct bitmap* p, uint32_t count);
void bitmap_set(struct bitmap* p, int32_t index);
void bitmap_clear(struct bitmap* p, int32_t index);
int8_t bitmap_get(struct bitmap* p, int32_t index);

#endif
